package com.community.community.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.community.community.pojo.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface UserMapper extends BaseMapper<User> {
    @Select("select * from user where user_name=#{userName} limit 1")
    User selectByUserName(String userName);

    @Select("select password from user where id = #{userId} ")
    String getPasswordById(Integer userId);
}
